var e = require;
var t = module;
var o = exports;
var n, i, r, a, c;
Object.defineProperty(o, "__esModule", {value: !0});
o.ParseUiConfig = o.BaseUiPath = o.DefUIMode = o.EmUIMode = o.EmUIAddition = o.EmUIFrom = o.UIDefZIndex = void 0;
(function (e) {
    e[(e.Bottom = -100)] = "Bottom";
    e[(e.Fixed = 0)] = "Fixed";
    e[(e.Module = 100)] = "Module";
    e[(e.Normal = 200)] = "Normal";
    e[(e.PopUp = 300)] = "PopUp";
    e[(e.TopModule = 400)] = "TopModule";
    e[(e.TopMsg = 500)] = "TopMsg";
    e[(e.SystemModule = 600)] = "SystemModule";
})((i = o.UIDefZIndex || (o.UIDefZIndex = {})));
(function (e) {
    e[(e.none = 0)] = "none";
    e[(e.Scene = 1)] = "Scene";
    e[(e.Popup = 2)] = "Popup";
})((r = o.EmUIFrom || (o.EmUIFrom = {})));
(function (e) {
    e[(e.destroyAllPopup = 0)] = "destroyAllPopup";
    e[(e.destroyPrePopup = 1)] = "destroyPrePopup";
    e[(e.hideAllPopup = 2)] = "hideAllPopup";
    e[(e.hidePrePopup = 3)] = "hidePrePopup";
    e[(e.destroyAllScene = 4)] = "destroyAllScene";
    e[(e.hideAllScene = 5)] = "hideAllScene";
})((a = o.EmUIAddition || (o.EmUIAddition = {})));
(function (e) {
    e[(e.SceneUI = 0)] = "SceneUI";
    e[(e.FullUI = 1)] = "FullUI";
    e[(e.DependUI = 2)] = "DependUI";
    e[(e.DepondCoinUI = 3)] = "DepondCoinUI";
    e[(e.DepondTabUI = 4)] = "DepondTabUI";
    e[(e.PopupUI = 5)] = "PopupUI";
    e[(e.PopupMsgUI = 6)] = "PopupMsgUI";
    e[(e.EffectUI = 7)] = "EffectUI";
    e[(e.LoadingUI = 8)] = "LoadingUI";
    e[(e.Module = 9)] = "Module";
})((c = o.EmUIMode || (o.EmUIMode = {})));
o.DefUIMode =
    (((n = {})[c.SceneUI] = {
        zIndex: i.Fixed,
        uiFrom: r.Scene,
        showPublicBg: !0,
        inShowEndHide: !0,
        uiAdditionType: a.destroyAllScene
    }),
    (n[c.FullUI] = {
        zIndex: i.PopUp,
        uiFrom: r.Popup,
        isIgnoreHide: !0,
        showPublicBg: !0,
        inShowEndHide: !0,
        uiAdditionType: a.hideAllScene
    }),
    (n[c.DependUI] = {zIndex: i.Module, skipLoading: !0}),
    (n[c.DepondCoinUI] = {zIndex: i.TopModule, skipLoading: !0}),
    (n[c.DepondTabUI] = {zIndex: i.TopModule, skipLoading: !0}),
    (n[c.PopupUI] = {zIndex: i.PopUp, uiFrom: r.Popup, uiAdditionType: a.hideAllPopup}),
    (n[c.PopupMsgUI] = {zIndex: i.TopMsg, uiFrom: r.Popup}),
    (n[c.EffectUI] = {zIndex: i.TopModule, skipLoading: !0, skipStack: !0}),
    (n[c.LoadingUI] = {zIndex: i.TopModule, skipLoading: !0}),
    n);
o.BaseUiPath = "/Panel/";
o.ParseUiConfig = function (e, t) {
    for (var n in t) {
        var i = t[n],
            r = Object.keys(i);
        void 0 !== i.uiMode &&
            (1 == r.length
                ? (t[n] = Object.assign({}, o.DefUIMode[i.uiMode] || {}))
                : (t[n] = Object.assign(Object.assign({}, o.DefUIMode[i.uiMode]), i)));
        t[n].dependUIArr = t[n].dependUIArr || [];
        null == t[n].prefab && (t[n].prefab = e[n]);
    }
    return t;
};
